<html>
<head><meta charset="utf-8"><title>rowan-next performance quirk · t-compiler/rust-analyzer · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/index.html">t-compiler/rust-analyzer</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/rowan-next.20performance.20quirk.html">rowan-next performance quirk</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="193690351"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/rowan-next%20performance%20quirk/near/193690351" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Christopher Durham <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/rowan-next.20performance.20quirk.html#193690351">(Apr 12 2020 at 02:28)</a>:</h4>
<p>If somebody wants an interesting benchmark to dissect, I've got one I don't quite understand in sorbus (rowan-next): <a href="https://github.com/CAD97/sorbus/pull/1#issuecomment-612549153" title="https://github.com/CAD97/sorbus/pull/1#issuecomment-612549153">https://github.com/CAD97/sorbus/pull/1#issuecomment-612549153</a></p>
<p>TL;DR is that a change to the way I'm iterating over green nodes' children array is producing a 9% regression in a benchmark of iterating one (large) node's children, and a 33% improvement in walking the entire tree. (At small scale, it seems flat iteration takes a much larger hit, but walking keeps the same improvement.)</p>
<p>My gut tells me the walk benchmark is "correct" here and the flat iteration benchmark is just measuring the wrong thing, but I've run out of my knowledge on how to track down this weird behavior. More details and the full criterion report are in the linked issue, I'm happy to answer questions here or on the issue (as well as run further experiments).</p>



<a name="193737552"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/rowan-next%20performance%20quirk/near/193737552" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Christopher Durham <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/rowan-next.20performance.20quirk.html#193737552">(Apr 13 2020 at 00:46)</a>:</h4>
<p>This is so annoying because I cannot for the life of it get any profiler working (on Windows). I can _debug_ Rust code in vscode, but I can't get Visual Studio to understand a Rust project enough to launch (or debug/profile) it.</p>



<a name="193737866"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/rowan-next%20performance%20quirk/near/193737866" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/rowan-next.20performance.20quirk.html#193737866">(Apr 13 2020 at 00:56)</a>:</h4>
<p>Intel VTune is a word associated with windows and profiling in my brain.<br>
Quick googling shows that at least one person made it work five years ago.</p>



<a name="193737871"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/rowan-next%20performance%20quirk/near/193737871" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nagisa <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/rowan-next.20performance.20quirk.html#193737871">(Apr 13 2020 at 00:56)</a>:</h4>
<p>There is a way to get visual studio to just open a plain executable, I could do it a fair number of times already</p>



<a name="193737875"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/rowan-next%20performance%20quirk/near/193737875" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nagisa <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/rowan-next.20performance.20quirk.html#193737875">(Apr 13 2020 at 00:57)</a>:</h4>
<p>IIRC I do it fairly roudaboutly – I think by opening the exe as a project?</p>



<a name="193737876"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/rowan-next%20performance%20quirk/near/193737876" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nagisa <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/rowan-next.20performance.20quirk.html#193737876">(Apr 13 2020 at 00:57)</a>:</h4>
<p>something like that.</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>